home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / networking / athena / moira / patch1 < prev    next >
Encoding:
Text File  |  1990-04-08  |  53.0 KB  |  1,722 lines

  1. This is patch #1 to Moira release 2.2, of Mon Apr  9 22:09:38 EDT 1990
  2.  
  3. BE SURE TO APPLY THIS PATCH WITH
  4.  
  5.    patch -p
  6.  
  7. TO PRESERVE THE DIRECTORY HIERARCHY.
  8.  
  9. The following bugs are fixed:
  10.  
  11. 1. create patchlevel.h
  12. 2. Problem with "make install" on top level directory.
  13. 3. Typecheck filesystem access flags from the database.
  14. 4. Improved error message from the dcm when a generator fails.
  15. 5. Only use optimized malloc with Ingres version 5 on a vax.
  16. 6. The no-host placeholder [NONE] failed to survive the hostname
  17.    canonicalization routine.
  18. 7. Allow mrtest to take a command from the Unix command line.
  19. 8. Improved error reporting for missing Ingres range statements.
  20. 9. Don't report false authentication errors when the database is
  21.    unavailable because of deadlock or timeout.
  22. 10. Don't allow multiple users with the same encrypted ID number.
  23. 11. Make sure the quota information is handled correctly when a
  24.     filesystem type is changed.
  25. 12. Allow the register_user query to work on users in state 6.
  26. 13. Improve authentication error message from blanche.
  27. 14. A number of typos are fixed in error messages in chfn.
  28. 15. If someone started userreg who was in half-enrolled state, he
  29.     would never be successful in registering.
  30. 16. Sometimes userreg would immediately clear the screen after
  31.     printing an error message.
  32. 17. Userreg sometimes incorrectly capitalized someone's middle name.
  33. 18. Userreg couldn't decode kerberos and some Moira errors.
  34. 19. The default path for the script when creating a new service entry
  35.     in moira was wrong.
  36. 20. Allow more of commands to moira client to be specified on the
  37.     command line before being prompted.
  38.  
  39. Be sure to set INGRESVER correctly in include/moira_site.h before
  40. recompiling your sources.
  41.  
  42.  
  43.  
  44. *** /dev/null    Mon Apr  9 17:05:09 1990
  45. --- patchlevel.h    Mon Apr  9 21:02:13 1990
  46. ***************
  47. *** 0 ****
  48. --- 1 ----
  49. + #define PATCHLEVEL 1
  50. *** /site/mar/moira/Makefile    Mon Mar 19 21:45:03 1990
  51. --- Makefile    Fri Mar 30 17:30:25 1990
  52. ***************
  53. *** 1,7 ****
  54.   # Makefile for SMS 2.0
  55.   #
  56.   #    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v $
  57. ! #    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v 1.13 90/03/19 21:44:56 mar Exp $
  58.   #    $Author: mar $
  59.   #
  60.   # (c) Copyright 1988 by the Massachusetts Institute of Technology.
  61. --- 1,7 ----
  62.   # Makefile for SMS 2.0
  63.   #
  64.   #    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v $
  65. ! #    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v 1.14 90/03/30 17:30:21 mar Exp $
  66.   #    $Author: mar $
  67.   #
  68.   # (c) Copyright 1988 by the Massachusetts Institute of Technology.
  69. ***************
  70. *** 25,31 ****
  71.           (cd $$i; make ${MFLAGS} all); done
  72.   
  73.   install:
  74. !     if [ ! -d bin ] then; mkdir bin; fi \
  75.       if [ -f /usr/rtingres/bin/eqc ]; then \
  76.           DIRS="${ALLDIRS} ${INSTALLDIRS}" ; \
  77.       else \
  78. --- 25,33 ----
  79.           (cd $$i; make ${MFLAGS} all); done
  80.   
  81.   install:
  82. !     if [ ! -d bin ]; then \
  83. !         mkdir bin ; \
  84. !     fi; \
  85.       if [ -f /usr/rtingres/bin/eqc ]; then \
  86.           DIRS="${ALLDIRS} ${INSTALLDIRS}" ; \
  87.       else \
  88. ***************
  89. *** 32,38 ****
  90.           DIRS="${RTDIRS} ${INSTALLDIRS}" ; \
  91.       fi; \
  92.       for i in $$DIRS; do \
  93. !         (cd $$i; make ${MFLAGS} DESTDIR=${DESTDIR} install); done
  94.   
  95.   world:
  96.       make clean
  97. --- 34,41 ----
  98.           DIRS="${RTDIRS} ${INSTALLDIRS}" ; \
  99.       fi; \
  100.       for i in $$DIRS; do \
  101. !         (cd $$i; make ${MFLAGS} DESTDIR=${DESTDIR} install); \
  102. !     done
  103.   
  104.   world:
  105.       make clean
  106. *** /site/mar/moira/db/newmoira.qc    Fri Mar 23 12:25:10 1990
  107. --- db/newmoira.qc    Fri Apr  6 12:57:25 1990
  108. ***************
  109. *** 1,4 ****
  110. ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/db/RCS/newmoira.qc,v 1.13 90/03/23 12:24:27 mar Exp $
  111.    *
  112.    * Creates a new sms database
  113.    *
  114. --- 1,4 ----
  115. ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/db/RCS/newmoira.qc,v 1.15 90/04/06 12:57:04 mar Exp $
  116.    *
  117.    * Creates a new sms database
  118.    *
  119. ***************
  120. *** 54,59 ****
  121. --- 54,66 ----
  122.              {"filesys", "TYPE", "NFS"},
  123.              {"filesys", "TYPE", "RVD"},
  124.              {"filesys", "TYPE", "AFS"},
  125. +            {"fs_access_AFS", "TYPE", "w"},
  126. +            {"fs_access_AFS", "TYPE", "n"},
  127. +            {"fs_access_NFS", "TYPE", "r"},
  128. +            {"fs_access_NFS", "TYPE", "n"},
  129. +            {"fs_access_NFS", "TYPE", "w"},
  130. +            {"fs_access_RVD", "TYPE", "r"},
  131. +            {"fs_access_RVD", "TYPE", "x"},
  132.              {"gaus", "TYPE", "LIST"},
  133.              {"gaus", "TYPE", "USER"},
  134.              {"gaus", "TYPE", "RLIST"},
  135. *** /site/mar/moira/dcm/dcm.c    Mon Mar 19 18:52:49 1990
  136. --- dcm/dcm.c    Mon Apr  9 18:42:10 1990
  137. ***************
  138. *** 7,17 ****
  139.    *
  140.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v $
  141.    * $Author: mar $
  142. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.13 90/03/19 18:52:46 mar Exp $
  143.    */
  144.   
  145.   #ifndef lint
  146. ! static char rcsid_dcm_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.13 90/03/19 18:52:46 mar Exp $";
  147.   #endif lint
  148.   
  149.   #include <stdio.h>
  150. --- 7,17 ----
  151.    *
  152.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v $
  153.    * $Author: mar $
  154. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.14 90/04/09 18:41:45 mar Exp $
  155.    */
  156.   
  157.   #ifndef lint
  158. ! static char rcsid_dcm_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.14 90/04/09 18:41:45 mar Exp $";
  159.   #endif lint
  160.   
  161.   #include <stdio.h>
  162. ***************
  163. *** 219,225 ****
  164.           waits.w_status = system(dfgen_cmd);
  165.           signal(SIGCHLD, cstat);
  166.           if (waits.w_termsig) {
  167. !             status = MR_TAR_FAIL;
  168.               com_err(whoami, status, " %s exited on signal %d",
  169.                   dfgen_prog, waits.w_termsig);
  170.           } else if (waits.w_retcode) {
  171. --- 219,225 ----
  172.           waits.w_status = system(dfgen_cmd);
  173.           signal(SIGCHLD, cstat);
  174.           if (waits.w_termsig) {
  175. !             status = MR_COREDUMP;
  176.               com_err(whoami, status, " %s exited on signal %d",
  177.                   dfgen_prog, waits.w_termsig);
  178.           } else if (waits.w_retcode) {
  179. *** /site/mar/moira/include/moira_site.h    Sat Mar 17 16:31:18 1990
  180. --- include/moira_site.h    Wed Apr  4 11:30:53 1990
  181. ***************
  182. *** 12,18 ****
  183.    *
  184.    *      $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v $
  185.    *      $Author: mar $
  186. !  *      $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v 1.17 90/03/17 16:31:12 mar Exp $
  187.    *    
  188.    *      Copyright 1988 by the Massachusetts Institute of Technology.
  189.    *
  190. --- 12,18 ----
  191.    *
  192.    *      $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v $
  193.    *      $Author: mar $
  194. !  *      $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v 1.18 90/04/04 11:30:27 mar Exp $
  195.    *    
  196.    *      Copyright 1988 by the Massachusetts Institute of Technology.
  197.    *
  198. ***************
  199. *** 37,42 ****
  200. --- 37,44 ----
  201.   /* #define SYSLOG */
  202.   /*   Athena local hacks -- other sites probably don't want this */
  203.   #define ATHENA
  204. + /* Ingres version number */
  205. + #define INGRESVER 5
  206.   
  207.   
  208.   #define NAME 0
  209. *** /site/mar/moira/rpc/mr_et.et    Sat Mar 17 16:37:44 1990
  210. --- rpc/mr_et.et    Mon Apr  9 19:21:20 1990
  211. ***************
  212. *** 1,6 ****
  213.   #    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v $
  214.   #    $Author: mar $
  215. ! #    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v 1.14 90/03/17 16:37:37 mar Exp $
  216.   #
  217.       error_table sms
  218.   
  219. --- 1,6 ----
  220.   #    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v $
  221.   #    $Author: mar $
  222. ! #    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v 1.16 90/04/09 19:21:13 mar Exp $
  223.   #
  224.       error_table sms
  225.   
  226. ***************
  227. *** 200,204 ****
  228. --- 200,210 ----
  229.   
  230.   ec    MR_LISTLOOP,
  231.       "Lists are not allowed to contain themselves as members"
  232. + ec    MR_INGRES_SOFTFAIL,
  233. +     "Temporary database failure, try again"
  234. + ec    MR_COREDUMP,
  235. +     "Subprocess coredumped"
  236.   
  237.       end
  238. *** /site/mar/moira/rpc/fixhost.c    Thu Mar 22 15:27:10 1990
  239. --- rpc/fixhost.c    Thu Apr  5 17:45:22 1990
  240. ***************
  241. *** 1,7 ****
  242.   /*
  243.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v $
  244.    *    $Author: mar $
  245. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.7 90/03/17 00:35:05 mar Exp $
  246.    *
  247.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  248.    *    For copying and distribution information, please see the file
  249. --- 1,7 ----
  250.   /*
  251.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v $
  252.    *    $Author: mar $
  253. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.8 90/04/05 17:45:11 mar Exp $
  254.    *
  255.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  256.    *    For copying and distribution information, please see the file
  257. ***************
  258. *** 9,15 ****
  259.    */
  260.   
  261.   #ifndef lint
  262. ! static char *rcsid_fixhost_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.7 90/03/17 00:35:05 mar Exp $";
  263.   #endif lint
  264.   
  265.   #include <mit-copyright.h>
  266. --- 9,15 ----
  267.    */
  268.   
  269.   #ifndef lint
  270. ! static char *rcsid_fixhost_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.8 90/04/05 17:45:11 mar Exp $";
  271.   #endif lint
  272.   
  273.   #include <mit-copyright.h>
  274. ***************
  275. *** 59,65 ****
  276.       return(strsave(tbuf));
  277.       }
  278.   
  279. !     if (index(host, '*') || index(host, '?'))
  280.         return(host);
  281.   
  282.       hp = gethostbyname(host);
  283. --- 59,65 ----
  284.       return(strsave(tbuf));
  285.       }
  286.   
  287. !     if (index(host, '*') || index(host, '?') || index(host, '['))
  288.         return(host);
  289.   
  290.       hp = gethostbyname(host);
  291. *** /site/mar/moira/test/test.c    Sat Mar 17 17:26:08 1990
  292. --- test/test.c    Mon Apr  9 15:02:43 1990
  293. ***************
  294. *** 1,7 ****
  295.   /*
  296.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v $
  297.    *    $Author: mar $
  298. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.19 90/03/17 17:26:01 mar Exp $
  299.    *
  300.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  301.    *    For copying and distribution information, please see the file
  302. --- 1,7 ----
  303.   /*
  304.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v $
  305.    *    $Author: mar $
  306. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.20 90/04/09 15:02:25 mar Exp $
  307.    *
  308.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  309.    *    For copying and distribution information, please see the file
  310. ***************
  311. *** 10,16 ****
  312.    */
  313.   
  314.   #ifndef lint
  315. ! static char *rcsid_test_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.19 90/03/17 17:26:01 mar Exp $";
  316.   #endif lint
  317.   
  318.   #include <mit-copyright.h>
  319. --- 10,16 ----
  320.    */
  321.   
  322.   #ifndef lint
  323. ! static char *rcsid_test_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.20 90/04/09 15:02:25 mar Exp $";
  324.   #endif lint
  325.   
  326.   #include <mit-copyright.h>
  327. ***************
  328. *** 49,54 ****
  329. --- 49,58 ----
  330.       if (status != 0) {
  331.           com_err(whoami, status, "Unable to create invocation");
  332.           exit(1);
  333. +     }
  334. +     if (argc > 1) {
  335. +         argv++;
  336. +         ss_execute_command(ss, argv);
  337.       }
  338.       ss_listen(ss, &status);
  339.       if (status != 0) {
  340. *** /site/mar/moira/server/mr_smalloc.c    Mon Mar 19 15:46:22 1990
  341. --- server/mr_smalloc.c    Fri Apr  6 17:09:35 1990
  342. ***************
  343. *** 148,153 ****
  344. --- 148,154 ----
  345.   #include <sys/time.h>
  346.   #include <sys/resource.h>
  347.   #endif /* BSD42 */
  348. + #include <moira_site.h>
  349.   
  350.   #ifdef scribblecheck
  351.   #define rcheck
  352. ***************
  353. *** 283,291 ****
  354. --- 284,298 ----
  355.   {
  356.     return(((struct mhead *)a_block-1)->mh_nbytes);
  357.   }
  358. + #if INGRESVER == 5 && defined(vax)
  359. + /* This is here to pull in our private version of meinitlst.o
  360. +  * so that we don't try to get the buggy Ingres 5.0 one.
  361. +  */
  362.   extern int MEinitLists();
  363.   
  364.   static int (*foo)() = MEinitLists;
  365. + #endif
  366.       
  367.   
  368.   /****************************************************************
  369. ***************
  370. *** 361,376 ****
  371.     nblks = 1;
  372.     if ((siz = nu) < 8)
  373.       nblks = 1 << ((siz = 8) - nu);
  374. ! #ifdef notdef
  375. !   if ((cp = sbrk (1 << (siz + 3))) == (char *) -1)
  376. !     return;            /* no more room! */
  377. ! #endif notdef
  378.     {
  379. !      char *tcp;      
  380. !      if (MEalloc(1, 1 << (siz+3), &tcp))
  381. !        return;            /* No more room! */
  382. !      cp = tcp;
  383.     }
  384.     if ((int) cp & 7)
  385.       {        /* shouldn't happen, but just in case */
  386.         cp = (char *) (((int) cp + 8) & ~7);
  387. --- 368,384 ----
  388.     nblks = 1;
  389.     if ((siz = nu) < 8)
  390.       nblks = 1 << ((siz = 8) - nu);
  391. ! #if INGRESVER == 5 && defined(vax)
  392.     {
  393. !       char *tcp;      
  394. !       if (MEalloc(1, 1 << (siz+3), &tcp))
  395. !     return;            /* No more room! */
  396. !       cp = tcp;
  397.     }
  398. + #else /* INGRESVER == 5 && defined(vax) */
  399. +   if ((cp = sbrk (1 << (siz + 3))) == (char *) -1)
  400. +     return;            /* no more room! */
  401. + #endif /* INGRESVER == 5 && defined(vax) */
  402.     if ((int) cp & 7)
  403.       {        /* shouldn't happen, but just in case */
  404.         cp = (char *) (((int) cp + 8) & ~7);
  405. *** /site/mar/moira/server/meinitlst.c    Mon Mar 19 15:44:47 1990
  406. --- server/meinitlst.c    Fri Apr  6 17:10:19 1990
  407. ***************
  408. *** 1,7 ****
  409.   /*
  410.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v $
  411.    *    $Author: mar $
  412. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.2 88/09/13 17:40:40 mar Exp $
  413.    *
  414.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  415.    *    For copying and distribution information, please see the file
  416. --- 1,7 ----
  417.   /*
  418.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v $
  419.    *    $Author: mar $
  420. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.3 90/04/04 18:28:50 mar Exp $
  421.    *
  422.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  423.    *    For copying and distribution information, please see the file
  424. ***************
  425. *** 9,25 ****
  426.    *
  427.    *     This code is a reverse-engineered version of
  428.    *     ~rtingres/lib/compatlib(meinitlst.o) with a better malloc and
  429. !  *     free.
  430.    */
  431.   
  432.   #ifndef lint
  433. ! static char *rcsid_meinitlst_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.2 88/09/13 17:40:40 mar Exp $";
  434.   #endif lint
  435.   
  436.   #include <mit-copyright.h>
  437.   #include <sys/errno.h>
  438.   #include <sys/types.h>
  439.   
  440.   /*
  441.    * entry points:
  442.    *     MEinitLists()
  443. --- 9,28 ----
  444.    *
  445.    *     This code is a reverse-engineered version of
  446.    *     ~rtingres/lib/compatlib(meinitlst.o) with a better malloc and
  447. !  *     free.  It only works with Ingres version 5 on the vax.
  448.    */
  449.   
  450.   #ifndef lint
  451. ! static char *rcsid_meinitlst_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.3 90/04/04 18:28:50 mar Exp $";
  452.   #endif lint
  453.   
  454.   #include <mit-copyright.h>
  455.   #include <sys/errno.h>
  456.   #include <sys/types.h>
  457. + #include <moira_site.h>
  458.   
  459. + #if INGRESVER == 5 && defined(vax)
  460.   /*
  461.    * entry points:
  462.    *     MEinitLists()
  463. ***************
  464. *** 87,94 ****
  465.       (void) free(adr);
  466.       return new_addr;
  467.   }
  468. ! #endif notdef
  469. ! #ifdef notdef
  470.   valloc(size)
  471.       int size;
  472.   {
  473. --- 90,96 ----
  474.       (void) free(adr);
  475.       return new_addr;
  476.   }
  477.   valloc(size)
  478.       int size;
  479.   {
  480. ***************
  481. *** 167,169 ****
  482. --- 169,172 ----
  483.   _memalign+e3:   ret
  484.   */
  485.   #endif notdef
  486. + #endif /* INGRESVER == 5 && defined(vax) */
  487. *** /site/mar/moira/server/Makefile    Mon Mar 19 20:51:28 1990
  488. --- server/Makefile    Mon Apr  9 12:38:48 1990
  489. ***************
  490. *** 1,6 ****
  491.   #    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v $
  492.   #    $Author: mar $
  493. ! #    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v 1.16 90/03/19 20:51:19 mar Exp $
  494.   #
  495.   
  496.   CFILES = startmoira.c mr_main.c mr_sauth.c mr_scall.c \
  497. --- 1,6 ----
  498.   #    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v $
  499.   #    $Author: mar $
  500. ! #    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v 1.17 90/04/09 12:38:30 mar Exp $
  501.   #
  502.   
  503.   CFILES = startmoira.c mr_main.c mr_sauth.c mr_scall.c \
  504. ***************
  505. *** 13,24 ****
  506.       mr_smalloc.o meinitlst.o increment.o cache.o
  507.   
  508.   GLUOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
  509. !     ../rpc/mr_et.o mr_srvdata.o mr_smalloc.o meinitlst.o \
  510.       ../rpc/krb_et.o mr_util.o increment.o cache.o
  511.   
  512.   GLUPOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
  513. !     ../../rpc/mr_et.o mr_srvdata.o mr_smalloc.o meinitlst.o \
  514. !     ../../rpc/krb_et.o mr_util.o increment.o cache.o
  515.   
  516.   
  517.   LIBS=../rpc/libmoira.a ../gdb/libgdb.a 
  518. --- 13,25 ----
  519.       mr_smalloc.o meinitlst.o increment.o cache.o
  520.   
  521.   GLUOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
  522. !     ../rpc/mr_et.o mr_srvdata.o mr_smalloc.o meinitlst.o mr_sbrk.o \
  523.       ../rpc/krb_et.o mr_util.o increment.o cache.o
  524.   
  525.   GLUPOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
  526. !     ../../rpc/profiled/mr_et.o mr_srvdata.o mr_smalloc.o \
  527. !     meinitlst.o mr_sbrk.o ../../rpc/profiled/krb_et.o mr_util.o \
  528. !     increment.o cache.o 
  529.   
  530.   
  531.   LIBS=../rpc/libmoira.a ../gdb/libgdb.a 
  532. *** /site/mar/moira/server/qrtn.qc    Mon Mar 19 15:42:32 1990
  533. --- server/qrtn.qc    Mon Apr  9 12:39:29 1990
  534. ***************
  535. *** 1,7 ****
  536.   /*
  537.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v $
  538.    *    $Author: mar $
  539. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.39 90/03/19 15:42:27 mar Exp $
  540.    *
  541.    *    Copyright (C) 1987, 1988 by the Massachusetts Institute of Technology
  542.    *    For copying and distribution information, please see the file
  543. --- 1,7 ----
  544.   /*
  545.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v $
  546.    *    $Author: mar $
  547. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.42 90/04/09 12:39:09 mar Exp $
  548.    *
  549.    *    Copyright (C) 1987, 1988 by the Massachusetts Institute of Technology
  550.    *    For copying and distribution information, please see the file
  551. ***************
  552. *** 10,16 ****
  553.    */
  554.   
  555.   #ifndef lint
  556. ! static char *rcsid_qrtn_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.39 90/03/19 15:42:27 mar Exp $";
  557.   #endif lint
  558.   
  559.   #include <mit-copyright.h>
  560. --- 10,16 ----
  561.    */
  562.   
  563.   #ifndef lint
  564. ! static char *rcsid_qrtn_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.42 90/04/09 12:39:09 mar Exp $";
  565.   #endif lint
  566.   
  567.   #include <mit-copyright.h>
  568. ***************
  569. *** 29,34 ****
  570. --- 29,35 ----
  571.   #define INGRES_BAD_DATE 4302
  572.   #define INGRES_DEADLOCK 4700
  573.   #define INGRES_TIMEOUT 4702
  574. + #define INGRES_NO_RANGE 2109
  575.   
  576.   /*
  577.    * ingerr: (supposedly) called when Ingres indicates an error.
  578. ***************
  579. *** 56,61 ****
  580. --- 57,66 ----
  581.       mr_errcode = MR_BUSY;
  582.       com_err(whoami, 0, "timed out getting lock");
  583.       break;
  584. +     case INGRES_NO_RANGE:
  585. +     mr_errcode = MR_INGRES_SOFTFAIL;
  586. +     com_err(whoami, 0, "INGRES missing range statement");
  587. +     break;
  588.       default:
  589.       mr_errcode = MR_INGRES_ERR;
  590.       com_err(whoami, MR_INGRES_ERR, " code %d\n", *num);
  591. ***************
  592. *** 798,804 ****
  593.    * owns.  Sets the kerberos ID and user ID.
  594.    */
  595.   
  596. ! set_krb_mapping(name, login, ok, kid, uid)
  597.   char *name;
  598.   char *login;
  599.   int ok;
  600. --- 803,809 ----
  601.    * owns.  Sets the kerberos ID and user ID.
  602.    */
  603.   
  604. ! int set_krb_mapping(name, login, ok, kid, uid)
  605.   char *name;
  606.   char *login;
  607.   int ok;
  608. ***************
  609. *** 815,825 ****
  610.   ##  repeat retrieve (u_id = krbmap.#users_id, k_id = krbmap.#string_id)
  611.   ##    where krbmap.string_id = strings.string_id and strings.string = @krbname
  612.   ##  inquire_equel (rowcount = "rowcount")
  613.       
  614.       if (rowcount == 1) {
  615.       *kid = -k_id;
  616.       *uid = u_id;
  617. !     return;
  618.       }
  619.   
  620.       if (name_to_id(name, "STRINGS", &k_id) == MR_SUCCESS)
  621. --- 820,831 ----
  622.   ##  repeat retrieve (u_id = krbmap.#users_id, k_id = krbmap.#string_id)
  623.   ##    where krbmap.string_id = strings.string_id and strings.string = @krbname
  624.   ##  inquire_equel (rowcount = "rowcount")
  625. +     if (ingres_errno) return(mr_errcode);
  626.       
  627.       if (rowcount == 1) {
  628.       *kid = -k_id;
  629.       *uid = u_id;
  630. !     return(MR_SUCCESS);
  631.       }
  632.   
  633.       if (name_to_id(name, "STRINGS", &k_id) == MR_SUCCESS)
  634. ***************
  635. *** 827,833 ****
  636.   
  637.       if (!ok) {
  638.       *uid = *kid;
  639. !     return;
  640.       }
  641.   
  642.       if (name_to_id(login, "USERS", uid) != MR_SUCCESS)
  643. --- 833,839 ----
  644.   
  645.       if (!ok) {
  646.       *uid = *kid;
  647. !     return(MR_SUCCESS);
  648.       }
  649.   
  650.       if (name_to_id(login, "USERS", uid) != MR_SUCCESS)
  651. ***************
  652. *** 835,840 ****
  653. --- 841,848 ----
  654.   
  655.       if (*kid == 0)
  656.         *kid = *uid;
  657. +     if (ingres_errno) return(mr_errcode);
  658. +     return(MR_SUCCESS);
  659.   ##}
  660.   
  661.   
  662. *** /site/mar/moira/server/qsupport.qc    Mon Mar 19 15:43:04 1990
  663. --- server/qsupport.qc    Mon Apr  9 21:49:04 1990
  664. ***************
  665. *** 1,7 ****
  666.   /*
  667.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v $
  668.    *    $Author: mar $
  669. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.49 90/03/19 15:42:34 mar Exp $
  670.    *
  671.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  672.    *    For copying and distribution information, please see the file
  673. --- 1,7 ----
  674.   /*
  675.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v $
  676.    *    $Author: mar $
  677. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.52 90/04/09 19:23:04 mar Exp $
  678.    *
  679.    *    Copyright (C) 1987 by the Massachusetts Institute of Technology
  680.    *    For copying and distribution information, please see the file
  681. ***************
  682. *** 10,16 ****
  683.    */
  684.   
  685.   #ifndef lint
  686. ! static char *rcsid_qsupport_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.49 90/03/19 15:42:34 mar Exp $";
  687.   #endif lint
  688.   
  689.   #include <mit-copyright.h>
  690. --- 10,16 ----
  691.    */
  692.   
  693.   #ifndef lint
  694. ! static char *rcsid_qsupport_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.52 90/04/09 19:23:04 mar Exp $";
  695.   #endif lint
  696.   
  697.   #include <mit-copyright.h>
  698. ***************
  699. *** 329,335 ****
  700. --- 329,341 ----
  701.       client *cl;
  702.   ##{
  703.   ##  int nuid, rowcount;
  704. + ##  char *mit_id;
  705.   
  706. +     mit_id = argv[U_MITID];
  707. + ##  retrieve (rowcount = any(u.#mit_id where u.#mit_id = mit_id))
  708. +     if (ingres_errno) return(mr_errcode);
  709. +     if (rowcount) return(MR_EXISTS);
  710.       if (!strcmp(argv[1], UNIQUE_UID) || atoi(argv[1]) == -1) {
  711.       if (set_next_object_id("uid", "users"))
  712.         return(MR_INGRES_ERR);
  713. ***************
  714. *** 660,670 ****
  715.   setup_afil(q, argv)
  716.       struct query *q;
  717.       char *argv[];
  718. ! {
  719. !     char *type;
  720.       int mach_id;
  721. !     char *name;
  722. !     char *access;  
  723.   
  724.       type = argv[1];
  725.       mach_id = *(int *)argv[2];
  726. --- 666,676 ----
  727.   setup_afil(q, argv)
  728.       struct query *q;
  729.       char *argv[];
  730. ! ##{
  731. !     char *type, *name;
  732.       int mach_id;
  733. ! ##  int ok;
  734. ! ##  char ftype[32], *access;
  735.   
  736.       type = argv[1];
  737.       mach_id = *(int *)argv[2];
  738. ***************
  739. *** 672,682 ****
  740.       access = argv[5];
  741.       var_phys_id = 0;
  742.   
  743.       if (!strcmp(type, "NFS"))
  744.       return (check_nfs(mach_id, name, access));
  745.       else
  746.       return(MR_SUCCESS);
  747. ! }
  748.   
  749.   
  750.   /* Verify the arguments, depending on the FStype.  Also, if this is an
  751. --- 678,694 ----
  752.       access = argv[5];
  753.       var_phys_id = 0;
  754.   
  755. +     sprintf(ftype, "fs_access_%s", type);
  756. + ##  retrieve (ok = any(alias.trans where alias.name = ftype and
  757. + ##                 alias.type = "TYPE" and alias.trans = access))
  758. +     if (ingres_errno) return(mr_errcode);
  759. +     if (ok == 0) return(MR_FILESYS_ACCESS);
  760.       if (!strcmp(type, "NFS"))
  761.       return (check_nfs(mach_id, name, access));
  762.       else
  763.       return(MR_SUCCESS);
  764. ! ##}
  765.   
  766.   
  767.   /* Verify the arguments, depending on the FStype.  Also, if this is an
  768. ***************
  769. *** 684,696 ****
  770.    * the new phys_id.
  771.    */
  772.   
  773. ! setup_ufil(q, argv)
  774.       struct query *q;
  775.       char *argv[];
  776.   ##{
  777.       int mach_id, status;
  778. !     char *type, *name, *access;  
  779. ! ##  int fid, total;
  780.   
  781.       type = argv[2];
  782.       mach_id = *(int *)argv[3];
  783. --- 696,710 ----
  784.    * the new phys_id.
  785.    */
  786.   
  787. ! setup_ufil(q, argv, cl)
  788.       struct query *q;
  789.       char *argv[];
  790. +     client *cl;
  791.   ##{
  792.       int mach_id, status;
  793. !     char *type, *name;  
  794. ! ##  int fid, total, who;
  795. ! ##  char *entity, ftype[32], *access;
  796.   
  797.       type = argv[2];
  798.       mach_id = *(int *)argv[3];
  799. ***************
  800. *** 698,704 ****
  801. --- 712,726 ----
  802.       access = argv[6];
  803.       var_phys_id = 0;
  804.       fid = *(int *)argv[0];
  805. +     who = cl->client_id;
  806. +     entity = cl->entity;
  807.   
  808. +     sprintf(ftype, "fs_access_%s", type);
  809. + ##  retrieve (total = any(alias.trans where alias.name = ftype and
  810. + ##                 alias.type = "TYPE" and alias.trans = access))
  811. +     if (ingres_errno) return(mr_errcode);
  812. +     if (total == 0) return(MR_FILESYS_ACCESS);
  813.       if (!strcmp(type, "NFS")) {
  814.       status = check_nfs(mach_id, name, access);
  815.   ##    replace nfsquota (phys_id = var_phys_id) where nfsquota.filsys_id = fid
  816. ***************
  817. *** 706,718 ****
  818.       return(status);
  819.       } else if (!strcmp(type, "AFS")) {
  820.       total = 0;
  821. ! ##    retrieve (total = sum(nfsquota.quota where nfsquota.filsys_id = fid))
  822.       if (ingres_errno) return(mr_errcode);
  823.       if (total != 0) {
  824.   ##        delete nfsquota where nfsquota.filsys_id = fid
  825.           if (ingres_errno) return(mr_errcode);
  826.   ##        append nfsquota (quota = total, filsys_id = fid,
  827. ! ##                 phys_id = 0, users_id = 0)
  828.           if (ingres_errno) return(mr_errcode);
  829.       }
  830.       } else {
  831. --- 728,742 ----
  832.       return(status);
  833.       } else if (!strcmp(type, "AFS")) {
  834.       total = 0;
  835. ! ##    retrieve (total = sum(nfsquota.quota where nfsquota.filsys_id = fid
  836. ! ##                  and nfsquota.phys_id != 0))
  837.       if (ingres_errno) return(mr_errcode);
  838.       if (total != 0) {
  839.   ##        delete nfsquota where nfsquota.filsys_id = fid
  840.           if (ingres_errno) return(mr_errcode);
  841.   ##        append nfsquota (quota = total, filsys_id = fid,
  842. ! ##                 phys_id = 0, users_id = 0,
  843. ! ##                 modtime = "now", modby = who, modwith = entity)
  844.           if (ingres_errno) return(mr_errcode);
  845.       }
  846.       } else {
  847. ***************
  848. *** 740,749 ****
  849.       register char *cp1;
  850.       register char *cp2;
  851.   
  852. -     caccess = (isupper(*access)) ? tolower(*access) : *access;
  853. -     if (caccess != 'r' && caccess != 'w' && caccess != 'n')
  854. -       return(MR_FILESYS_ACCESS);
  855.       status = MR_NFS;
  856.   ##  range of np is nfsphys
  857.   ##  repeat retrieve (var_phys_id = np.#nfsphys_id, dir = trim(np.#dir))
  858. --- 764,769 ----
  859. ***************
  860. *** 2488,2494 ****
  861.   
  862.       /* find user */
  863.   ##  repeat retrieve (users_id = u.#users_id)
  864. ! ##    where u.#uid = @uid and (u.status = 0 or u.status = 5)
  865.   ##  inquire_equel(rowcount = "rowcount");
  866.       if (rowcount == 0)
  867.         return(MR_NO_MATCH);
  868. --- 2508,2514 ----
  869.   
  870.       /* find user */
  871.   ##  repeat retrieve (users_id = u.#users_id)
  872. ! ##    where u.#uid = @uid and (u.status = 0 or u.status = 5 or u.status = 6)
  873.   ##  inquire_equel(rowcount = "rowcount");
  874.       if (rowcount == 0)
  875.         return(MR_NO_MATCH);
  876. *** /site/mar/moira/clients/blanche/blanche.c    Sat Mar 17 16:48:55 1990
  877. --- clients/blanche/blanche.c    Fri Apr  6 17:01:34 1990
  878. ***************
  879. *** 1,4 ****
  880. ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.12 90/03/17 16:48:52 mar Exp $
  881.    *
  882.    * Command line oriented Moira List tool.
  883.    *
  884. --- 1,4 ----
  885. ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.13 90/04/06 17:01:20 mar Exp $
  886.    *
  887.    * Command line oriented Moira List tool.
  888.    *
  889. ***************
  890. *** 21,27 ****
  891.   #include <moira_site.h>
  892.   
  893.   #ifndef LINT
  894. ! static char blanche_rcsid[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.12 90/03/17 16:48:52 mar Exp $";
  895.   #endif
  896.   
  897.   
  898. --- 21,27 ----
  899.   #include <moira_site.h>
  900.   
  901.   #ifndef LINT
  902. ! static char blanche_rcsid[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.13 90/04/06 17:01:20 mar Exp $";
  903.   #endif
  904.   
  905.   
  906. ***************
  907. *** 182,191 ****
  908.       }
  909.   
  910.       if (!noauth && (status = mr_auth("blanche"))) {
  911. !     com_err(whoami, status, "unable to authenticate to Moira");
  912. !     com_err(whoami, 0,
  913. !         " Try the -noauth flag if you don't need authentication");
  914. !     exit(2);
  915.       }
  916.   
  917.       /* display list info if requested to */
  918. --- 182,195 ----
  919.       }
  920.   
  921.       if (!noauth && (status = mr_auth("blanche"))) {
  922. !     if (status == MR_USER_AUTH)
  923. !       com_err(whoami, status, "");
  924. !     else {
  925. !         com_err(whoami, status, "unable to authenticate to Moira");
  926. !         com_err(whoami, 0,
  927. !             " Try the -noauth flag if you don't need authentication");
  928. !         exit(2);
  929. !     }
  930.       }
  931.   
  932.       /* display list info if requested to */
  933. *** /site/mar/moira/clients/passwd/chfn.c    Sat Mar 17 17:19:08 1990
  934. --- clients/passwd/chfn.c    Mon Mar 26 05:42:35 1990
  935. ***************
  936. *** 3,15 ****
  937.    * and distribution information, see the file "mit-copyright.h". 
  938.    *
  939.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v $
  940. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.8 90/03/17 17:19:04 mar Exp $
  941. !  * $Author: mar $
  942.    *
  943.    */
  944.   
  945.   #ifndef lint
  946. ! static char *rcsid_chfn_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.8 90/03/17 17:19:04 mar Exp $";
  947.   #endif not lint
  948.   
  949.   /*
  950. --- 3,15 ----
  951.    * and distribution information, see the file "mit-copyright.h". 
  952.    *
  953.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v $
  954. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.9 90/03/26 05:42:13 marc Exp $
  955. !  * $Author: marc $
  956.    *
  957.    */
  958.   
  959.   #ifndef lint
  960. ! static char *rcsid_chfn_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.9 90/03/26 05:42:13 marc Exp $";
  961.   #endif not lint
  962.   
  963.   /*
  964. ***************
  965. *** 129,141 ****
  966.   
  967.       status = mr_connect(NULL);
  968.       if (status) {
  969. !     com_err(whoami, status, " while connecting to Moira");
  970.       exit(1);
  971.       }
  972.   
  973.       status = mr_motd(&motd);
  974.       if (status) {
  975. !         com_err(whoami, status, " unable to check server status");
  976.       leave(1);
  977.       }
  978.       if (motd) {
  979. --- 129,141 ----
  980.   
  981.       status = mr_connect(NULL);
  982.       if (status) {
  983. !     com_err(whoami, status, "while connecting to Moira");
  984.       exit(1);
  985.       }
  986.   
  987.       status = mr_motd(&motd);
  988.       if (status) {
  989. !         com_err(whoami, status, "unable to check server status");
  990.       leave(1);
  991.       }
  992.       if (motd) {
  993. ***************
  994. *** 146,152 ****
  995.       status = mr_auth("chfn");    /* Don't use argv[0] - too easy to fake */
  996.       if (status) {
  997.       com_err(whoami, status, 
  998. !         " while authenticating -- run \"kinit\" and try again.");
  999.       leave(1);
  1000.       }
  1001.   
  1002. --- 146,152 ----
  1003.       status = mr_auth("chfn");    /* Don't use argv[0] - too easy to fake */
  1004.       if (status) {
  1005.       com_err(whoami, status, 
  1006. !         "while authenticating -- run \"kinit\" and try again.");
  1007.       leave(1);
  1008.       }
  1009.   
  1010. ***************
  1011. *** 171,177 ****
  1012.       if (status = mr_query("get_finger_by_login", q_argc, q_argv, 
  1013.                  get_user_info, (char *) &old_info))
  1014.       {
  1015. !     com_err(whoami, status, " while getting user information.");
  1016.       leave(2);
  1017.       }
  1018.   
  1019. --- 171,177 ----
  1020.       if (status = mr_query("get_finger_by_login", q_argc, q_argv, 
  1021.                  get_user_info, (char *) &old_info))
  1022.       {
  1023. !     com_err(whoami, status, "while getting user information.");
  1024.       leave(2);
  1025.       }
  1026.   
  1027. ***************
  1028. *** 197,203 ****
  1029.       if (status = mr_query("update_finger_by_login", q_argc, q_argv,
  1030.                  scream, (char *)NULL))
  1031.       {
  1032. !     com_err(whoami, status, " while updating finger information.");
  1033.       leave(1);
  1034.       }
  1035.   
  1036. --- 197,203 ----
  1037.       if (status = mr_query("update_finger_by_login", q_argc, q_argv,
  1038.                  scream, (char *)NULL))
  1039.       {
  1040. !     com_err(whoami, status, "while updating finger information.");
  1041.       leave(1);
  1042.       }
  1043.   
  1044. ***************
  1045. *** 334,340 ****
  1046.       GETINFO("Office address (Exs: E40-342 or 2-108)", 
  1047.           office_address, FALSE);
  1048.       GETINFO("Office phone (Ex: 3-1300)", office_phone, TRUE);
  1049. !     GETINFO("MIT department (Exs: 9, Biology, Information Services", 
  1050.           mit_department, FALSE);
  1051.       GETINFO("MIT year (Exs: 1989, '91, Faculty, Grad)", mit_year, FALSE);
  1052.   }
  1053. --- 334,340 ----
  1054.       GETINFO("Office address (Exs: E40-342 or 2-108)", 
  1055.           office_address, FALSE);
  1056.       GETINFO("Office phone (Ex: 3-1300)", office_phone, TRUE);
  1057. !     GETINFO("MIT department (Exs: 9, Biology, Information Services)", 
  1058.           mit_department, FALSE);
  1059.       GETINFO("MIT year (Exs: 1989, '91, Faculty, Grad)", mit_year, FALSE);
  1060.   }
  1061. *** /site/mar/moira/clients/userreg/userreg.c    Thu Mar 15 14:31:16 1990
  1062. --- clients/userreg/userreg.c    Mon Apr  9 19:09:01 1990
  1063. ***************
  1064. *** 2,8 ****
  1065.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v $
  1066.    * $Author: mar $
  1067.    * $Locker:  $
  1068. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.17 90/03/15 14:31:01 mar Exp $ 
  1069.    *
  1070.    *  (c) Copyright 1988 by the Massachusetts Institute of Technology.
  1071.    *  For copying and distribution information, please see the file
  1072. --- 2,8 ----
  1073.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v $
  1074.    * $Author: mar $
  1075.    * $Locker:  $
  1076. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.20 90/04/09 19:08:33 mar Exp $ 
  1077.    *
  1078.    *  (c) Copyright 1988 by the Massachusetts Institute of Technology.
  1079.    *  For copying and distribution information, please see the file
  1080. ***************
  1081. *** 10,16 ****
  1082.    */
  1083.   
  1084.   #ifndef lint
  1085. ! static char    *rcsid_userreg_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.17 90/03/15 14:31:01 mar Exp $";
  1086.   #endif    lint
  1087.   
  1088.   #include <mit-copyright.h>
  1089. --- 10,16 ----
  1090.    */
  1091.   
  1092.   #ifndef lint
  1093. ! static char    *rcsid_userreg_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.20 90/04/09 19:08:33 mar Exp $";
  1094.   #endif    lint
  1095.   
  1096.   #include <mit-copyright.h>
  1097. ***************
  1098. *** 236,243 ****
  1099.           user_has_login = 0;
  1100.           sleep(1);
  1101.           return 0;
  1102. -     case UREG_NO_PASSWD_YET:
  1103.       case UREG_HALF_ENROLLED:
  1104.           user_is_valid = 1;
  1105.           user_has_login = 1;
  1106.           display_text_line ("You have chosen a login name, but you have not yet chosen a password.");
  1107. --- 236,245 ----
  1108.           user_has_login = 0;
  1109.           sleep(1);
  1110.           return 0;
  1111.       case UREG_HALF_ENROLLED:
  1112. +         enrollment = 1;
  1113. +         /* fall through to: */
  1114. +     case UREG_NO_PASSWD_YET:
  1115.           user_is_valid = 1;
  1116.           user_has_login = 1;
  1117.           display_text_line ("You have chosen a login name, but you have not yet chosen a password.");
  1118. ***************
  1119. *** 299,304 ****
  1120. --- 301,310 ----
  1121.       case ETIMEDOUT:
  1122.       case UREG_MISC_ERROR:
  1123.           display_text(NETWORK_DOWN);
  1124. +         display_text_line(" ");
  1125. +         sprintf(line, "The specific error was: %s",
  1126. +             error_message(result));
  1127. +         display_text_line(line);
  1128.           wait_for_user();
  1129.           return (0);
  1130.           
  1131. ***************
  1132. *** 587,592 ****
  1133. --- 593,599 ----
  1134.   do_replace()
  1135.   {
  1136.       int status;
  1137. +     char buf[100];
  1138.       
  1139.       /*
  1140.        * replaces a user in the database. If there is an error, it informs
  1141. ***************
  1142. *** 603,608 ****
  1143. --- 610,620 ----
  1144.       timer_on();
  1145.       if (status) {
  1146.           display_text (NETWORK_DOWN);
  1147. +         display_text_line(" ");
  1148. +         sprintf(buf, "The specific error was: %s",
  1149. +             error_message(status));
  1150. +         display_text_line(buf);
  1151. +         wait_for_user();
  1152.           return (-1);
  1153.       } else return 0;
  1154.   }
  1155. ***************
  1156. *** 663,670 ****
  1157.           while (p2 >= cp && isspace(*p2)) *(--p2) = '\0';
  1158.       }
  1159.       /* Make it capitalized */
  1160. !     for (p2=cp; *p2; p2++) {
  1161. !         if (isupper(*p2)) *p2 = tolower(*p2);
  1162. !     }
  1163. !     if (islower(*cp)) *cp=toupper(*cp);
  1164.   }
  1165. --- 675,679 ----
  1166.           while (p2 >= cp && isspace(*p2)) *(--p2) = '\0';
  1167.       }
  1168.       /* Make it capitalized */
  1169. !     FixCase(cp);
  1170.   }
  1171. *** /site/mar/moira/clients/userreg/reg_stubs.c    Sat Mar 17 17:24:37 1990
  1172. --- clients/userreg/reg_stubs.c    Mon Apr  9 14:25:27 1990
  1173. ***************
  1174. *** 1,7 ****
  1175.   /*
  1176.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v $
  1177.    *    $Author: mar $
  1178. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.15 90/03/17 17:24:31 mar Exp $
  1179.    *
  1180.    *  (c) Copyright 1988 by the Massachusetts Institute of Technology.
  1181.    *  For copying and distribution information, please see the file
  1182. --- 1,7 ----
  1183.   /*
  1184.    *    $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v $
  1185.    *    $Author: mar $
  1186. !  *    $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.16 90/04/09 14:25:16 mar Exp $
  1187.    *
  1188.    *  (c) Copyright 1988 by the Massachusetts Institute of Technology.
  1189.    *  For copying and distribution information, please see the file
  1190. ***************
  1191. *** 9,15 ****
  1192.    */
  1193.   
  1194.   #ifndef lint
  1195. ! static char *rcsid_reg_stubs_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.15 90/03/17 17:24:31 mar Exp $";
  1196.   #endif lint
  1197.   
  1198.   #include <mit-copyright.h>
  1199. --- 9,15 ----
  1200.    */
  1201.   
  1202.   #ifndef lint
  1203. ! static char *rcsid_reg_stubs_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.16 90/04/09 14:25:16 mar Exp $";
  1204.   #endif lint
  1205.   
  1206.   #include <mit-copyright.h>
  1207. ***************
  1208. *** 42,48 ****
  1209.       extern char *getenv(), **hes_resolve();
  1210.       
  1211.       initialize_ureg_error_table();
  1212. !     
  1213.       seq_no = getpid();
  1214.   
  1215.       host = NULL;
  1216. --- 42,50 ----
  1217.       extern char *getenv(), **hes_resolve();
  1218.       
  1219.       initialize_ureg_error_table();
  1220. !     initialize_krb_error_table(); 
  1221. !     initialize_sms_error_table();
  1222. !    
  1223.       seq_no = getpid();
  1224.   
  1225.       host = NULL;
  1226. *** /site/mar/moira/clients/moira/dcmmaint.c    Sat Mar 17 17:10:21 1990
  1227. --- clients/moira/dcmmaint.c    Tue Mar 27 11:41:27 1990
  1228. ***************
  1229. *** 1,4 ****
  1230. ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/dcmmaint.c,v 1.7 90/03/17 17:10:15 mar Exp $
  1231.    *
  1232.    * Copyright 1987, 1988 by the Massachusetts Institute of Technology.
  1233.    * For copying and distribution information, please see the file
  1234. --- 1,4 ----
  1235. ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/dcmmaint.c,v 1.8 90/03/27 11:40:41 mar Exp $
  1236.    *
  1237.    * Copyright 1987, 1988 by the Massachusetts Institute of Technology.
  1238.    * For copying and distribution information, please see the file
  1239. ***************
  1240. *** 164,170 ****
  1241.       argv[SC_INTERVAL] = strsave("1440");
  1242.       sprintf(tmp, "/tmp/%s.out", name);
  1243.       argv[SC_TARGET] = strsave(tmp);
  1244. !     sprintf(tmp, "/u1/mr/bin/%s.sh", name);
  1245.       argv[SC_SCRIPT] = strsave(tmp);
  1246.       argv[SC_TYPE] = strsave("UNIQUE");
  1247.       argv[SC_ENABLE] = strsave("1");
  1248. --- 164,170 ----
  1249.       argv[SC_INTERVAL] = strsave("1440");
  1250.       sprintf(tmp, "/tmp/%s.out", name);
  1251.       argv[SC_TARGET] = strsave(tmp);
  1252. !     sprintf(tmp, "%s/%s.sh", BIN_DIR, name);
  1253.       argv[SC_SCRIPT] = strsave(tmp);
  1254.       argv[SC_TYPE] = strsave("UNIQUE");
  1255.       argv[SC_ENABLE] = strsave("1");
  1256. *** /site/mar/moira/clients/moira/attach.c    Sat Mar 17 17:10:07 1990
  1257. --- clients/moira/attach.c    Thu Apr  5 17:36:09 1990
  1258. ***************
  1259. *** 1,5 ****
  1260.   #if (!defined(lint) && !defined(SABER))
  1261. !   static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.21 90/03/17 17:09:54 mar Exp $";
  1262.   #endif
  1263.   
  1264.   /*    This is the file attach.c for the MOIRA Client, which allows a nieve
  1265. --- 1,5 ----
  1266.   #if (!defined(lint) && !defined(SABER))
  1267. !   static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.23 90/04/05 17:35:57 mar Exp $";
  1268.   #endif
  1269.   
  1270.   /*    This is the file attach.c for the MOIRA Client, which allows a nieve
  1271. ***************
  1272. *** 13,19 ****
  1273.    *
  1274.    *      $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v $
  1275.    *      $Author: mar $
  1276. !  *      $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.21 90/03/17 17:09:54 mar Exp $
  1277.    *    
  1278.    *      Copyright 1988 by the Massachusetts Institute of Technology.
  1279.    *
  1280. --- 13,19 ----
  1281.    *
  1282.    *      $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v $
  1283.    *      $Author: mar $
  1284. !  *      $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.23 90/04/05 17:35:57 mar Exp $
  1285.    *    
  1286.    *      Copyright 1988 by the Massachusetts Institute of Technology.
  1287.    *
  1288. ***************
  1289. *** 244,250 ****
  1290.   char ** info;
  1291.   Bool name;
  1292.   {
  1293. !     char temp_buf[BUFSIZ], *newname;
  1294.       int fsgroup = 0;
  1295.   
  1296.       Put_message("");
  1297. --- 244,250 ----
  1298.   char ** info;
  1299.   Bool name;
  1300.   {
  1301. !     char temp_buf[BUFSIZ], *newname, access_type[32];
  1302.       int fsgroup = 0;
  1303.   
  1304.       Put_message("");
  1305. ***************
  1306. *** 276,282 ****
  1307.       if (!fsgroup) {
  1308.       GetValueFromUser("Filesystem's Pack Name", &info[FS_PACK]);
  1309.       GetValueFromUser("Filesystem's Mount Point", &info[FS_M_POINT]);
  1310. !     GetValueFromUser("Filesystem's Default Access", &info[FS_ACCESS]);
  1311.       }
  1312.       GetValueFromUser("Comments about this Filesystem", &info[FS_COMMENTS]);
  1313.       GetValueFromUser("Filesystem's owner (user)", &info[FS_OWNER]);
  1314. --- 276,284 ----
  1315.       if (!fsgroup) {
  1316.       GetValueFromUser("Filesystem's Pack Name", &info[FS_PACK]);
  1317.       GetValueFromUser("Filesystem's Mount Point", &info[FS_M_POINT]);
  1318. !     sprintf(access_type, "fs_access_%s", info[FS_TYPE]);
  1319. !     GetTypeFromUser("Filesystem's Default Access", access_type,
  1320. !             &info[FS_ACCESS]);
  1321.       }
  1322.       GetValueFromUser("Comments about this Filesystem", &info[FS_COMMENTS]);
  1323.       GetValueFromUser("Filesystem's owner (user)", &info[FS_OWNER]);
  1324. *** /site/mar/moira/clients/moira/menu.h    Tue Dec 27 18:49:43 1988
  1325. --- clients/moira/menu.h    Mon Apr  9 18:03:14 1990
  1326. ***************
  1327. *** 1,3 ****
  1328. --- 1,5 ----
  1329. + /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.h,v 1.2 90/04/09 18:02:53 mar Exp $ */
  1330.   #define MAX_ARGC 16        /* Maximum argument count per line */
  1331.   #define MAX_ARGLEN 128        /* Maximum length of an argument */
  1332.   #define MAX_LINES 16        /* Maximum number of lines per menu */
  1333. ***************
  1334. *** 40,42 ****
  1335. --- 42,48 ----
  1336.   #define NULLMENU ((struct menu *) 0)
  1337.   #define SUBMENU(cmd, doc, menu) { NULLFUNC, menu, 1, { { cmd, doc } } }
  1338.   #define SIMPLEFUNC(cmd, doc, func) { func, NULLMENU, 1, { { cmd, doc } } }
  1339. + /* Unused words found on parsed command line */
  1340. + extern int parsed_argc;
  1341. + extern char **parsed_argv;
  1342. *** /site/mar/moira/clients/moira/menu.c    Sat Mar 17 17:12:09 1990
  1343. --- clients/moira/menu.c    Mon Apr  9 18:04:06 1990
  1344. ***************
  1345. *** 5,11 ****
  1346.    *
  1347.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v $
  1348.    * $Author: mar $
  1349. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.27 90/03/17 00:19:53 mar Exp $
  1350.    *
  1351.    * Generic menu system module.
  1352.    *
  1353. --- 5,11 ----
  1354.    *
  1355.    * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v $
  1356.    * $Author: mar $
  1357. !  * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.28 90/04/09 18:03:56 mar Exp $
  1358.    *
  1359.    * Generic menu system module.
  1360.    *
  1361. ***************
  1362. *** 18,24 ****
  1363.    */
  1364.   
  1365.   #ifndef lint
  1366. ! static char rcsid_menu_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.27 90/03/17 00:19:53 mar Exp $";
  1367.   
  1368.   #endif lint
  1369.   
  1370. --- 18,24 ----
  1371.    */
  1372.   
  1373.   #ifndef lint
  1374. ! static char rcsid_menu_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.28 90/04/09 18:03:56 mar Exp $";
  1375.   
  1376.   #endif lint
  1377.   
  1378. ***************
  1379. *** 63,68 ****
  1380. --- 63,70 ----
  1381.   #define NULLMS ((struct menu_screen *) 0)
  1382.   
  1383.   Menu *top_menu;            /* Root for command search */
  1384. + int parsed_argc;        /* used by extern routines to get additional */
  1385. + char **parsed_argv;        /*   comand line input */
  1386.   
  1387.   /*
  1388.    * Hook function to cause error messages to be printed through
  1389. ***************
  1390. *** 212,221 ****
  1391.       int toggle_logging();
  1392.       
  1393.       /* Entry function gets called with old menu_screen still current */
  1394. !     if (m->m_entry != NULLFUNC)
  1395.       if (m->m_entry(m, margc, margv) == DM_QUIT)
  1396.           return DM_NORMAL;
  1397.   
  1398.       /* The following get run only in curses mode */
  1399.       if (cur_ms != NULLMS) {
  1400.       /* Get a menu_screen */
  1401. --- 214,230 ----
  1402.       int toggle_logging();
  1403.       
  1404.       /* Entry function gets called with old menu_screen still current */
  1405. !     if (m->m_entry != NULLFUNC) {
  1406.       if (m->m_entry(m, margc, margv) == DM_QUIT)
  1407.           return DM_NORMAL;
  1408. +     if (parsed_argc > 0) {
  1409. +         margc = parsed_argc + 1;
  1410. +         margv = --parsed_argv;
  1411. +     }
  1412. +     }
  1413.   
  1414. +     parsed_argc = 0;
  1415.       /* The following get run only in curses mode */
  1416.       if (cur_ms != NULLMS) {
  1417.       /* Get a menu_screen */
  1418. ***************
  1419. *** 274,295 ****
  1420.       /* This is here because we may be coming from another menu */
  1421.       if (cur_ms != NULL)
  1422.           touchwin(my_ms->ms_screen);
  1423. !     /* Get a command */
  1424. !     if (!Prompt_input("Command: ", buf, sizeof(buf))) {
  1425. !         if (cur_ms == NULLMS &&
  1426. !         feof(stdin))
  1427. !           sprintf(buf, "quit");
  1428. !         else
  1429.             continue;
  1430.       }
  1431. -     /* Parse it into the argument list */
  1432. -     /* If there's nothing there, try again */
  1433. -     /* Initialize argv */
  1434. -     for (argc = 0; argc < MAX_ARGC; argc++)
  1435. -         argv[argc] = argvals[argc];
  1436. -     if ((argc = Parse_words(buf, argv, MAX_ARGLEN)) == 0)
  1437. -         continue;
  1438.       if ((line = atoi(argv[0])) > 0 && line <= m->m_length) {
  1439.           command = &m->m_lines[line - 1];
  1440.       }
  1441. --- 283,314 ----
  1442.       /* This is here because we may be coming from another menu */
  1443.       if (cur_ms != NULL)
  1444.           touchwin(my_ms->ms_screen);
  1445. !     if (margc > 1) {
  1446. !         /* Initialize argv */
  1447. !         for (argc = 0; argc < MAX_ARGC; argc++)
  1448. !           argv[argc] = argvals[argc];
  1449. !         argc = margc - 1;
  1450. !         for (i = 1; i < margc; i++)
  1451. !           strcpy(argvals[i - 1], margv[i]);
  1452. !         margc = 0;
  1453. !     } else {
  1454. !         /* Get a command */
  1455. !         if (!Prompt_input("Command: ", buf, sizeof(buf))) {
  1456. !         if (cur_ms == NULLMS &&
  1457. !             feof(stdin))
  1458. !           sprintf(buf, "quit");
  1459. !         else
  1460. !           continue;
  1461. !         }
  1462. !         /* Parse it into the argument list */
  1463. !         /* If there's nothing there, try again */
  1464. !         /* Initialize argv */
  1465. !         for (argc = 0; argc < MAX_ARGC; argc++)
  1466. !           argv[argc] = argvals[argc];
  1467. !         if ((argc = Parse_words(buf, argv, MAX_ARGLEN)) == 0)
  1468.             continue;
  1469.       }
  1470.       if ((line = atoi(argv[0])) > 0 && line <= m->m_length) {
  1471.           command = &m->m_lines[line - 1];
  1472.       }
  1473. ***************
  1474. *** 349,354 ****
  1475. --- 368,375 ----
  1476.                     argvals[argc], sizeof(argvals[argc])))
  1477.           goto punt_command;
  1478.       }
  1479. +     parsed_argc = argc - command->ml_argc;
  1480. +     parsed_argv = &(argv[command->ml_argc]);
  1481.       if (command->ml_function != NULLFUNC) {
  1482.           /* If it's got a function, call it */
  1483.           quitflag = command->ml_function(argc, argv);
  1484. ***************
  1485. *** 368,377 ****
  1486.           }
  1487.           if (m->m_exit != NULLFUNC)
  1488.           m->m_exit(m);
  1489.           return (DM_QUIT);
  1490.       }
  1491.       punt_command:
  1492. !     ;
  1493.       }
  1494.   }
  1495.   
  1496. --- 389,399 ----
  1497.           }
  1498.           if (m->m_exit != NULLFUNC)
  1499.           m->m_exit(m);
  1500. +         parsed_argc = 0;
  1501.           return (DM_QUIT);
  1502.       }
  1503.       punt_command:
  1504. !     parsed_argc = 0;
  1505.       }
  1506.   }
  1507.   
  1508. *** /site/mar/moira/clients/moira/utils.c    Sat Mar 17 17:11:39 1990
  1509. --- clients/moira/utils.c    Mon Apr  9 18:06:24 1990
  1510. ***************
  1511. *** 1,5 ****
  1512.   #if (!defined(lint) && !defined(SABER))
  1513. !   static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.21 90/03/17 17:11:31 mar Exp $";
  1514.   #endif lint
  1515.   
  1516.   /*    This is the file utils.c for the MOIRA Client, which allows a nieve
  1517. --- 1,5 ----
  1518.   #if (!defined(lint) && !defined(SABER))
  1519. !   static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.25 90/04/09 18:05:03 mar Exp $";
  1520.   #endif lint
  1521.   
  1522.   /*    This is the file utils.c for the MOIRA Client, which allows a nieve
  1523. ***************
  1524. *** 11,17 ****
  1525.    *
  1526.    *      $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v $
  1527.    *      $Author: mar $
  1528. !  *      $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.21 90/03/17 17:11:31 mar Exp $
  1529.    *    
  1530.    *      Copyright 1988 by the Massachusetts Institute of Technology.
  1531.    *
  1532. --- 11,17 ----
  1533.    *
  1534.    *      $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v $
  1535.    *      $Author: mar $
  1536. !  *      $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.25 90/04/09 18:05:03 mar Exp $
  1537.    *    
  1538.    *      Copyright 1988 by the Massachusetts Institute of Technology.
  1539.    *
  1540. ***************
  1541. *** 262,268 ****
  1542.    *    Arguments: prompt - the prompt string.
  1543.    *                 buf, buflen - buffer to be returned and its MAX size?
  1544.    *                 default value for the answer.
  1545. !  *    Returns: the value returned by prompt_input.
  1546.    */
  1547.   
  1548.   int
  1549. --- 262,268 ----
  1550.    *    Arguments: prompt - the prompt string.
  1551.    *                 buf, buflen - buffer to be returned and its MAX size?
  1552.    *                 default value for the answer.
  1553. !  *    Returns: zero on failure
  1554.    */
  1555.   
  1556.   int
  1557. ***************
  1558. *** 274,279 ****
  1559. --- 274,288 ----
  1560.       char tmp[BUFSIZ];
  1561.       int ans;
  1562.   
  1563. +     if (parsed_argc > 0) {
  1564. +     parsed_argc--;
  1565. +     strncpy(buf, parsed_argv[0], buflen);
  1566. +     sprintf(tmp, "%s: %s", prompt, buf);
  1567. +     Put_message(tmp);
  1568. +     parsed_argv++;
  1569. +     return(1);
  1570. +     }
  1571.       (void) sprintf(tmp, "%s [%s]: ", prompt, def ? def : "");
  1572.       ans = Prompt_input(tmp, buf, buflen);
  1573.       if (ans == 0) {
  1574. ***************
  1575. *** 387,393 ****
  1576.       Put_message("Please use a non-empty name.");
  1577.       else if (index(s, ' '))
  1578.       Put_message("You cannot use space (' ') in this name.");
  1579. !     else if (index(s, WILDCARD))
  1580.       Put_message("Wildcards not accepted here.");
  1581.       else
  1582.       return TRUE;
  1583. --- 396,402 ----
  1584.       Put_message("Please use a non-empty name.");
  1585.       else if (index(s, ' '))
  1586.       Put_message("You cannot use space (' ') in this name.");
  1587. !     else if (index(s, '*') || index(s, '?') || index(s, '['))
  1588.       Put_message("Wildcards not accepted here.");
  1589.       else
  1590.       return TRUE;
  1591. ***************
  1592. *** 465,471 ****
  1593.   {
  1594.       char buf[BUFSIZ];
  1595.   
  1596. !     if (PromptWithDefault(prompt, buf, BUFSIZ, *pointer) == -1)
  1597.       return(SUB_ERROR);
  1598.   
  1599.   /* 
  1600. --- 474,480 ----
  1601.   {
  1602.       char buf[BUFSIZ];
  1603.   
  1604. !     if (PromptWithDefault(prompt, buf, BUFSIZ, *pointer) == 0)
  1605.       return(SUB_ERROR);
  1606.   
  1607.   /* 
  1608. ***************
  1609. *** 803,809 ****
  1610.       }
  1611.       elem = (struct qelem *) malloc(sizeof(struct qelem));
  1612.       ce = (struct cache_elem *) malloc(sizeof(struct cache_elem));
  1613. !     ce->cache_name = tname;
  1614.       ce->cache_data = QueueTop(oelem);
  1615.       elem->q_data = (char  *)ce;
  1616.       AddQueue(elem, cache);
  1617. --- 818,824 ----
  1618.       }
  1619.       elem = (struct qelem *) malloc(sizeof(struct qelem));
  1620.       ce = (struct cache_elem *) malloc(sizeof(struct cache_elem));
  1621. !     ce->cache_name = strsave(tname);
  1622.       ce->cache_data = QueueTop(oelem);
  1623.       elem->q_data = (char  *)ce;
  1624.       AddQueue(elem, cache);
  1625. ***************
  1626. *** 849,856 ****
  1627.       return(GetTypeFromUser(prompt, tname, pointer));
  1628.       }
  1629.       for (elem = GetTypeValues(tname); elem; elem = elem->q_forw) {
  1630. !     if (!cistrcmp(elem->q_data, *pointer))
  1631.           return(SUB_NORMAL);
  1632.       }
  1633.       sprintf(buffer, "\"%s\" is not a legal value for %s.  Use one of:",
  1634.           *pointer, tname);
  1635. --- 864,873 ----
  1636.       return(GetTypeFromUser(prompt, tname, pointer));
  1637.       }
  1638.       for (elem = GetTypeValues(tname); elem; elem = elem->q_forw) {
  1639. !     if (!cistrcmp(elem->q_data, *pointer)) {
  1640. !         strcpy(*pointer, elem->q_data);
  1641.           return(SUB_NORMAL);
  1642. +     }
  1643.       }
  1644.       sprintf(buffer, "\"%s\" is not a legal value for %s.  Use one of:",
  1645.           *pointer, tname);
  1646. ***************
  1647. *** 865,873 ****
  1648.       argv[0] = tname;
  1649.       argv[1] = "TYPE";
  1650.       argv[2] = *pointer;
  1651. !     for (p = argv[2]; *p; p++)
  1652.           if (islower(*p))
  1653. !         *p = toupper(*p);
  1654.       if (stat = do_mr_query("add_alias", 3, argv, Scream, NULL)) {
  1655.           com_err(program_name, stat, " in add_alias");
  1656.       } else {
  1657. --- 882,892 ----
  1658.       argv[0] = tname;
  1659.       argv[1] = "TYPE";
  1660.       argv[2] = *pointer;
  1661. !     /* don't uppercase access flags.  Do uppercase everything else */
  1662. !     if (strncmp(tname, "fs_access", 9))
  1663. !       for (p = argv[2]; *p; p++)
  1664.           if (islower(*p))
  1665. !           *p = toupper(*p);
  1666.       if (stat = do_mr_query("add_alias", 3, argv, Scream, NULL)) {
  1667.           com_err(program_name, stat, " in add_alias");
  1668.       } else {
  1669. *** /site/mar/moira/doc/install.mss    Fri Mar 23 12:38:29 1990
  1670. --- doc/install.mss    Fri Apr  6 12:01:26 1990
  1671. ***************
  1672. *** 51,56 ****
  1673. --- 51,60 ----
  1674.   for the sake of backwards compatibility.  You probably don't need
  1675.   these.
  1676.   
  1677. + Define @b(INGRESVER) to be the major version number of the Ingres
  1678. + release you are using (i.e. 4, 5, or 6).  This is used by some server
  1679. + code which attempts to work around certain Ingres bugs.
  1680.   At the end of the file are a number of defines of filenames and
  1681.   directories that the server will use.  These directories are referred
  1682.   to by name below.  You may change them to arrange the disk usage on
  1683. *** /site/mar/moira/doc/install.doc    Fri Mar 23 12:38:28 1990
  1684. --- doc/install.doc    Mon Apr  9 22:25:28 1990
  1685. ***************
  1686. *** 46,52 ****
  1687.         for the sake of backwards compatibility.  You  probably  don't  need
  1688.         these.
  1689.   
  1690. !    6. At  the  end  of  the  file are a number of defines of filenames and
  1691.         directories that  the  server  will  use.    These  directories  are
  1692.         referred  to by name below.  You may change them to arrange the disk
  1693.         usage on your Moira server differently.
  1694. --- 46,56 ----
  1695.         for the sake of backwards compatibility.  You  probably  don't  need
  1696.         these.
  1697.   
  1698. !    6. Define  INGRESVER  to  be  the  major  version  number of the Ingres
  1699. !       release you are using (i.e. 4, 5, or 6).    This  is  used  by  some
  1700. !       server code which attempts to work around certain Ingres bugs.
  1701. !    7. At  the  end  of  the  file are a number of defines of filenames and
  1702.         directories that  the  server  will  use.    These  directories  are
  1703.         referred  to by name below.  You may change them to arrange the disk
  1704.         usage on your Moira server differently.
  1705.